// 设置响应头的中间件
module.exports = async (context, next) => {
    const contentType = 'application/json; charset=utf-8';
    context.set('Content-Tpye', contentType);
    context.response.body = '{"success": "true"}';
    context.set("Access-Control-Allow-Origin", "*");
    context.set("Access-Control-Allow-Methods", "OPTIONS, GET, PUT, POST, DELETE")
    await next();
}